package com.zenithsun.news.newsinfo.model;

import java.sql.Timestamp;
import java.util.Date;
import java.util.List;
import java.util.Set;

import com.alibaba.fastjson.annotation.JSONField;
import com.zenithsun.news.newscolumns.model.NewsColumns;

/**
 * Newsinfo entity. @author MyEclipse Persistence Tools
 */

public class Newsinfo implements java.io.Serializable {

	// Fields

	private String id;
	private NewsColumns newsColumns;
	private String newsTypeId;
	private String title;
	private String content;
	private String coverPath;
	private String correspondent;
	private String photographer;
	private String editor;
	private String keyword;
	private String remark;
	private Short isTop=0;
	private Short isStriking=0;
	private Short isCarousel=0;
	private long pageViewCounter = 0;
	public long getPageViewCounter() {
		return pageViewCounter;
	}

	public void setPageViewCounter(long pageViewCounter) {
		this.pageViewCounter = pageViewCounter;
	}

	@JSONField(format = "yyyy-MM-dd HH:mm:ss")
	private Date createTime;
	@JSONField(format = "yyyy-MM-dd")
	private Date publishTime;
	private String publishGroup;
	private Date showTime;
	private String type;
	private String picPath;
	private String picTempPath;
	private int picNum;
	private String snId;
	private Short state=-1;
	private String subTitle;
	private String nabstract;
	/**
	 * 全文检索-是否删除，1表示删除，0表示正常使用数据
	 */
	private Short isDelete=0;
	
	/**
	 * 全文检索-更新时间
	 */
	private Date updateTime;
	
	public Short getIsDelete() {
		return isDelete;
	}

	public void setIsDelete(Short isDelete) {
		this.isDelete = isDelete;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public Short getState() {
		return state;
	}

	public void setState(Short state) {
		this.state = state;
	}

	/**
	 * 增加新闻详情（图片）的属性，只做显示用
	 * @author wanglei@enersun.com.cn
	 */
	private List<Newsdetailinfo> newsdetails;
	// Constructors

	public List<Newsdetailinfo> getNewsdetails() {
		return newsdetails;
	}

	public void setNewsdetails(List<Newsdetailinfo> newsdetails) {
		this.newsdetails = newsdetails;
	}

	/** default constructor */
	public Newsinfo() {
	}

	/** minimal constructor */
	public Newsinfo(String id) {
		this.id = id;
	}

	/** minimal constructor */
	public Newsinfo(String id, String newsColumnsId, String title,
			String content, String coverPath, String editor, String keyword,
			Short isTop, Short isStriking, Short isCarousel,
			Timestamp createTime, String type) {
		this.id = id;
		this.title = title;
		this.content = content;
		this.coverPath = coverPath;
		this.editor = editor;
		this.keyword = keyword;
		this.isTop = isTop;
		this.isStriking = isStriking;
		this.isCarousel = isCarousel;
		this.createTime = createTime;
		this.type = type;
	}

	/** full constructor */
	public Newsinfo(String id, String newsColumnsId, String newsTypeId,
			String title, String content, String coverPath,
			String correspondent, String photographer, String editor,
			String keyword, String remark, Short isTop, Short isStriking,
			Short isCarousel, Timestamp createTime, Timestamp publishTime,
			String publishGroup, Timestamp showTime, String type,
			Set newsdetailinfos) {
		this.id = id;
		this.newsTypeId = newsTypeId;
		this.title = title;
		this.content = content;
		this.coverPath = coverPath;
		this.correspondent = correspondent;
		this.photographer = photographer;
		this.editor = editor;
		this.keyword = keyword;
		this.remark = remark;
		this.isTop = isTop;
		this.isStriking = isStriking;
		this.isCarousel = isCarousel;
		this.createTime = createTime;
		this.publishTime = publishTime;
		this.publishGroup = publishGroup;
		this.showTime = showTime;
		this.type = type;
	}

	// Property accessors

	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public String getNewsTypeId() {
		return this.newsTypeId;
	}

	public void setNewsTypeId(String newsTypeId) {
		this.newsTypeId = newsTypeId;
	}

	public String getTitle() {
		return this.title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getContent() {
		return this.content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getCoverPath() {
		return this.coverPath;
	}

	public void setCoverPath(String coverPath) {
		this.coverPath = coverPath;
	}

	public String getCorrespondent() {
		return this.correspondent;
	}

	public void setCorrespondent(String correspondent) {
		this.correspondent = correspondent;
	}

	public String getPhotographer() {
		return this.photographer;
	}

	public void setPhotographer(String photographer) {
		this.photographer = photographer;
	}

	public String getEditor() {
		return this.editor;
	}

	public void setEditor(String editor) {
		this.editor = editor;
	}

	public String getKeyword() {
		return this.keyword;
	}

	public void setKeyword(String keyword) {
		this.keyword = keyword;
	}

	public String getRemark() {
		return this.remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

	public Short getIsTop() {
		return this.isTop;
	}

	public void setIsTop(Short isTop) {
		this.isTop = isTop;
	}

	public Short getIsStriking() {
		return this.isStriking;
	}

	public void setIsStriking(Short isStriking) {
		this.isStriking = isStriking;
	}

	public Short getIsCarousel() {
		return this.isCarousel;
	}

	public void setIsCarousel(Short isCarousel) {
		this.isCarousel = isCarousel;
	}

	public String getPublishGroup() {
		return this.publishGroup;
	}

	public void setPublishGroup(String publishGroup) {
		this.publishGroup = publishGroup;
	}

	public String getType() {
		return this.type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public NewsColumns getNewsColumns() {
		return newsColumns;
	}

	public void setNewsColumns(NewsColumns newsColumns) {
		this.newsColumns = newsColumns;
	}

	public String getPicTempPath() {
		return picTempPath;
	}

	public void setPicTempPath(String picTempPath) {
		this.picTempPath = picTempPath;
	}

	public String getPicPath() {
		return picPath;
	}

	public void setPicPath(String picPath) {
		this.picPath = picPath;
	}

	public int getPicNum() {
		return picNum;
	}

	public void setPicNum(int picNum) {
		this.picNum = picNum;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public Date getPublishTime() {
		return publishTime;
	}

	public void setPublishTime(Date publishTime) {
		this.publishTime = publishTime;
	}

	public Date getShowTime() {
		return showTime;
	}

	public void setShowTime(Date showTime) {
		this.showTime = showTime;
	}

	public String getSnId() {
		return snId;
	}

	public void setSnId(String snId) {
		this.snId = snId;
	}

	public String getSubTitle() {
		return subTitle;
	}

	public void setSubTitle(String subTitle) {
		this.subTitle = subTitle;
	}

	public String getNabstract() {
		return nabstract;
	}

	public void setNabstract(String nabstract) {
		this.nabstract = nabstract;
	}
}